<!DOCTYPE HTML>
<html>

<head>
    <meta charset="utf-8">
    <title></title>
    <meta name="viewport"
        content="width=device-width,initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no" />
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <meta name="full-screen" content="true" />
    <meta name="screen-orientation" content="portrait" />
    <meta name="x5-fullscreen" content="true" />
    <meta name="360-fullscreen" content="true" />
    <meta http-equiv="cache-control" content="no-cache,no-store,must-revalidate" />
    <meta http-equiv="Pragma" content="no-cache" />
    <meta http-equiv="expires" content="0" />
    <style>
        html,
        body {
            -ms-touch-action: none;
            background: #000;
            padding: 0;
            border: 0;
            margin: 0;
            height: 100%;
            -webkit-user-select: none;
            /* 禁止选中文本（如无文本选中需求，此为必选项） */
            user-select: none;
        }

        video {
            object-fit: cover;
        }

        a,
        img {
            -webkit-touch-callout: none;
        }
    </style>
    <script type="text/javascript">
        (function (w, d) {
            function setSize() {
                var screenWidth = d.documentElement.clientWidth;
                var currentFontSize = screenWidth * 100 / 750;
                d.documentElement.style.fontSize = currentFontSize + 'px';
            }
            w.addEventListener('resize', setSize);
            w.addEventListener('pageShow', setSize)
            w.addEventListener('DOMContentLoaded', setSize)
        })(window, document)
    </script>
</head>
<script type="text/javascript" src="https://res.wx.qq.com/open/js/jweixin-1.6.0.js"></script>
<script type="text/javascript" src="https://creat.elloworld.cn/common/js/vconsole.min.js"></script>
<script>
    // var vConsole = new VConsole();
    // console.log(location.href);
</script>

<body>
    <!-- <video id="P1video"  poster="" style="display: none;z-index: 999;" playsinline="true"
        webkit-playsinline="true" x5-video-player-type="h5" x-video-player-fullscreen="true" x-webkit-airplay="true"
        src="https://show.malukeji.com/h5/2022/202210/jinlongyu/Video/video1.mp4"></video> -->
    <!-- <audio style="display:none; height: 0" id="bg_music" preload="auto" src="./resource/assets/Sound/bg.mp3"
    loop="loop"></audio> -->
    <div style="margin: auto;width: 100%;height: 100%;" class="egret-player" data-entry-class="Main"
        data-orientation="portrait" data-scale-mode="fixedWidth" data-frame-rate="60" data-content-width="750"
        data-content-height="1453" data-show-paint-rect="false" data-multi-fingered="2" data-show-fps="false"
        data-show-log="false" data-show-fps-style="x:0,y:0,size:12,textColor:0xffffff,bgAlpha:0.9">
    </div>
    <script>
        var loadScript = function (list, callback) {
            var loaded = 0;
            var loadNext = function () {
                loadSingleScript(list[loaded], function () {
                    loaded++;
                    if (loaded >= list.length) {
                        callback();
                    }
                    else {
                        loadNext();
                    }
                })
            };
            loadNext();
        };

        var loadSingleScript = function (src, callback) {
            var s = document.createElement('script');
            s.async = false;
            s.src = src;
            s.addEventListener('load', function () {
                s.parentNode.removeChild(s);
                s.removeEventListener('load', arguments.callee, false);
                callback();
            }, false);
            document.body.appendChild(s);
        };

        var xhr = new XMLHttpRequest();
        xhr.open('GET', './manifest.json?v=' + Math.random(), true);
        xhr.addEventListener("load", function () {
            var manifest = JSON.parse(xhr.response);
            var list = manifest.initial.concat(manifest.game);
            loadScript(list, function () {
                /**
                 * {
                 * "renderMode":, //Engine rendering mode, "canvas" or "webgl"
                 * "audioType": 0 //Use the audio type, 0: default, 2: web audio, 3: audio
                 * "antialias": //Whether the anti-aliasing is enabled in WebGL mode, true: on, false: off, defaults to false
                 * "calculateCanvasScaleFactor": //a function return canvas scale factor
                 * }
                 **/
                egret.runEgret({
                    renderMode: "webgl", audioType: 0, calculateCanvasScaleFactor: function (context) {
                        var backingStore = context.backingStorePixelRatio ||
                            context.webkitBackingStorePixelRatio ||
                            context.mozBackingStorePixelRatio ||
                            context.msBackingStorePixelRatio ||
                            context.oBackingStorePixelRatio ||
                            context.backingStorePixelRatio || 1;
                        return (window.devicePixelRatio || 1) / backingStore;
                    }
                });
            });
        });
        xhr.send(null);
    </script>
    <!-- <script>
    autoPlayMusic();
    function muscStop() {
        document.getElementById('bg_music').pause();
    }
    function muscPlay() {
        document.getElementById('bg_music').play();
    }
    
    function autoPlayMusic() {
        // 自动播放音乐效果，解决浏览器或者APP自动播放问题
        // function musicInBrowserHandler() {
        //     musicPlay(true);
        //     document.removeEventListener('touchstart', musicInBrowserHandler);
        // }
        // document.addEventListener('touchstart', musicInBrowserHandler);

        // 自动播放音乐效果，解决微信自动播放问题
        function musicInWeixinHandler() {
            musicPlay(true);
            document.addEventListener("WeixinJSBridgeReady", function () {
                musicPlay(true);
            }, false);
            document.removeEventListener('DOMContentLoaded', musicInWeixinHandler);
        }
        document.addEventListener('DOMContentLoaded', musicInWeixinHandler);
    }
    function musicPlay(isPlay) {
        var media = document.querySelector('#bg_music');
        if (isPlay && media.paused) {
            media.play();
        }
        if (!isPlay && !media.paused) {
            media.pause();
        }
    }
</script> -->
</body>

</html>